#ifndef MPQREADER_H
#define MPQREADER_H
#pragma once
//We need the Windows data types for the Storm prototypes
#include <windows.h>
#include <tchar.h>
#include "../Log/LOG.h"



//Just in case anyone is still using C out there
#ifdef __cplusplus
extern "C" 
{
#endif
	//Storm prototypes
	BOOL WINAPI SFileOpenArchive(LPCSTR lpFileName, DWORD dwMPQID, DWORD dwUnknown, HANDLE *lphMPQ);
	BOOL WINAPI SFileCloseArchive(HANDLE hMPQ);
	BOOL WINAPI SFileOpenFileEx(HANDLE hMPQ, LPCSTR lpFileName, DWORD dwSearchScope, HANDLE *lphFile);
	BOOL WINAPI SFileCloseFile(HANDLE hFile);
	BOOL WINAPI SFileReadFile(HANDLE hFile, LPVOID lpBuffer, DWORD nNumberOfBytesToRead, LPDWORD lpNumberOfBytesRead, LPOVERLAPPED lpOverlapped);
	DWORD WINAPI SFileGetFileSize(HANDLE hFile, LPDWORD lpdwFileSizeHigh);
	DWORD WINAPI SFileSetFilePointer(HANDLE hFile, long nDistanceToMove, DWORD dwUnused, DWORD dwMoveMethod);
	LCID WINAPI SFileSetLocale(LCID lcNewLocale);
#ifdef __cplusplus
}
#endif
void readMPQ(LPCSTR szArchiveName,char* szFileName,LPCWSTR szOutFileName);
#endif //#ifndef MPQREADER_H
